package com.woniuxy.store.client;

import com.woniuxy.store.client.param.foodParam.InsertFoodPropParams;
import com.woniuxy.store.client.param.foodParam.InsertFoodPropValueParams;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;
import result.Result;

import java.util.List;

@FeignClient(contextId = "FoodPropClient",name = "store",path = "/store/food")
public interface FoodPropClient {
    @PostMapping("/insertFoodProp")
    public Result insertFoodProp(@RequestBody InsertFoodPropParams param);

    @DeleteMapping("/deleteFoodProp")
    public Result deleteFoodProp(@RequestParam("foodPropId") Integer foodPropId);

    @GetMapping({"/searchFoodPropBySpuId"})
    Result searchFoodPropBySpuId(@RequestParam("spuId") Integer spuId);

    @PostMapping("/insertFoodPropValue")
    public Result insertFoodPropValue(@RequestBody InsertFoodPropValueParams param);

    @DeleteMapping("/deleteFoodPropValue")
    public Result deleteFoodPropValue(@RequestParam("foodPropValueId") Integer foodPropValueId);

    @GetMapping({"/searchFoodPropValueByFoodPropId"})
    Result searchFoodPropValueByFoodPropId(@RequestParam("foodPropId") Integer foodPropId);
}
